# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-filebytes
_pkgname=filebytes
pkgver=0.10.0
pkgrel=1
pkgdesc='Classes to parse the following file formats - Executable and Linking Format (ELF) , Portable Executable (PE), Mach-O and OAT (Android Runtime).'
url='https://pypi.org/project/filebytes/#files'
arch=('any')
license=('BSD')
depends=('python2')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('29a28b0d7cc7cce87dc719ff491f2fddb25105e1aae4521e0cbf9ab07ffa5a9df3f23fa31479244613f7ae5a23cc9d0444e1dd67e66153e3c0268b7cba888b14')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
}

